package org.easylookandfeel.adapter;

import org.easylookandfeel.core.LookAndFeelManager;

/**
 * Implements {@link LookAndFeelAdapter} interface in order to ease concrete
 * implementation. It automatically stores {@link LookAndFeelManager} and make
 * it available to its subclasses through {@link #getManager()} protected
 * method.
 * 
 * @author pcmnac@gmail.com
 * 
 */
public abstract class AbstractLookAndFeelAdapter implements LookAndFeelAdapter {

	/**
	 * The stored {@link LookAndFeelManager}.
	 */
	private LookAndFeelManager manager;

	/**
	 * @see org.easylookandfeel.adapter.LookAndFeelAdapter#setManager(org.easylookandfeel.core.LookAndFeelManager)
	 */
	public void setManager(LookAndFeelManager manager) {
		this.manager = manager;
	}

	/**
	 * Returns stored {@link LookAndFeelManager}.
	 * 
	 * @return Stored {@link LookAndFeelManager}.
	 */
	protected LookAndFeelManager getManager() {
		return manager;
	}

}
